package org.nocepko.android.sumc;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.Window;


public class SumcActivity extends Activity {
	
	private final static String TAG = "sumc.Main";
	
	private final static int DEBUG_ID = Menu.FIRST;
	
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        
        requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
        
        // TODO: refactor the main layout
        setContentView(R.layout.main);
    }
        

    @Override
	public boolean onCreateOptionsMenu(Menu menu) {
    	menu.add(0, DEBUG_ID, 0, R.string.debug);
    	return super.onCreateOptionsMenu(menu);
	}

	@Override
	public boolean onOptionsItemSelected(MenuItem item) {
		switch (item.getItemId()) {
		case DEBUG_ID:
			startActivity(new Intent(this, DebugActivity.class));
			return true;
		}
		return super.onOptionsItemSelected(item);
	}

}